<!DOCTYPE html>
<html>
	<head>
		<title>SIGNUP</title>
		<meta name="viewport" content="width=device-width, initial-scale=1">
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<script type="application/x-javascript">
			addEventListener("load", function() {
				setTimeout(hideURLbar, 0);
			}, false);

			function hideURLbar() {
				window.scrollTo(0, 1);
			}
		</script>
		<!-- Custom Theme files -->
		<link href="./css/font-awesome.min.css" rel="stylesheet" type="text/css" media="all"/>
		<link href="./css/login_snow.css" rel="stylesheet" type="text/css" media="all" />
		<link href="./css/login_style.css" rel="stylesheet" type="text/css" media="all" />
	</head>
	<body>
		<div class="snow-container">
			<div class="snow foreground"></div>
			<div class="snow foreground layered"></div>
			<div class="snow middleground"></div>
			<div class="snow middleground layered"></div>
			<div class="snow background"></div>
			<div class="snow background layered"></div>
		</div>

		<div class="top-buttons-agileinfo">
			<a href="login.html">登录</a><a href="signup.html" class="active">注册</a>
		</div>
		<h1>锤子商城</h1>
		<div class="main-agileits">
			<!--form-stars-here-->
			<div class="form-w3-agile">
				<h2 class="sub-agileits-w3layouts">注册</h2>
				<form>
					<input type="text" name="Username" placeholder="用户名" id="username"/>
					<input type="password" name="Password" placeholder="输入密码" id="password1"/>
					<input type="password" name="Password" placeholder="确认密码"  id="password2"/>
					<div class="submit-w3l">
						<input type="button" value="注册" id="btn_signup">
					</div>
				</form>
			</div>
		</div>
		<!--//form-ends-here-->
		<!-- copyright -->
		<div class="copyright w3-agile">
			<p> © 2017 Internship Sign In & Sign Up Form . All rights reserved </p>
		</div>
		<!-- //copyright -->
		<script type="text/javascript" src="./js/jquery3.js"></script>
		<script src="js/jquery.tips.js" type="text/javascript" charset="utf-8"></script>
		<script type="text/javascript">
			function check() {
				if ($("#username").val() == "") {
					$("#username").tips({
						side: 2,
						msg: '用户名不能为空',
						bg: '#2ba6df',
						time: 3
					});
					$("#username").focus();
					return false;
				}
				if ($("#password1").val() == "") {
					$("#password1").tips({
						side: 2,
						msg: '密码不能为空',
						bg: '#2ba6df',
						time: 3
					});
					$("#password1").focus();
					return false;
				}
				if ($("#password2").val() != $("#password1").val()) {
					$("#password2").tips({
						side: 2,
						msg: '两次密码不相同',
						bg: '#2ba6df',
						time: 3
					});
					$("#password2").focus();
					return false;
				}
				return true;
			}
			$(function() {
				$("#btn_signup").click(function() {
					if (check()) {
						console.log("成功");
					}
				})
			
			
			})
		</script>
	</body>
</html>
